package com.sharding.test.service.impl;

import com.sharding.test.entity.TsLabels;
import com.sharding.test.mapper.TsLabelsMapper;
import com.sharding.test.service.TsLabelsService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author yangpeiyu
 * @since 2021-10-22
 */
@Service
public class TsLabelsServiceImpl extends ServiceImpl<TsLabelsMapper, TsLabels> implements TsLabelsService {
	
	@Autowired
	private TsLabelsMapper mapper;

	@Override
	public boolean create(TsLabels labels) {
		return mapper.insert(labels)>0;
	}

	@Override
	public TsLabels getLabelsById(Integer id) {
		return mapper.selectById(id);
	}

}
